#!/bin/bash
ID=`ps -ef | grep "audi-vehicle-status-chart-report.jar" | grep -v "$0" | grep -v "grep" | awk '{print $2}'`
echo $ID
echo "---------------"
for id in $ID
do
kill -9 $id
echo "killed $id"
done
echo "---------------"
nohup  nohup java -jar audi-vehicle-status-chart-report.jar >> /timafawvw/logs/audi-vehicle-status-chart-report/log.txt 2>&1 &
nohup tail -500f /timafawvw/logs/audi-vehicle-status-chart-report/log.txt 2>&1 &